import com.java.base.exercise.T;
import com.java.base.exercise.designmode.builder.Person;
import org.apache.commons.lang3.StringUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import java.util.*;
import java.util.stream.Collectors;

/**
 * @Author RenPu
 * @Date 2021/12/28 15:36
 * @Version 1.0
 * @Description:
 **/
public class test008 {

    private final static Logger logger = LoggerFactory.getLogger(test008.class);


    public static void main1(String[] args) {

        try {
           while (true){
                List<Person> list = new ArrayList<>();

                list.add(new Person("王五",10));
                list.add(new Person("z赵六",1));
                list.add(new Person("麻七",8));
                List<String> collect = list.stream().map(Person::getName).collect(Collectors.toList());
                System.out.println(collect);
//                int i=1/0;
            }
        } catch (Exception e) {
            System.out.println("触发异常..............");
            System.exit(1);
        }


    }


    public static void main(String[] args) {

//        String mm="";
//        Map<String, Object> map2=new HashMap<>();
//        map2.put("mian","");
//
//        //boolean mian = StringUtils.isNotBlank(map2.getOrDefault("mian",""));
//        String str="1101".substring(0,2);
//        System.out.println(str);
//
////            Person person=null;
////
////            person.getName();
//
//            if(0>1) mm="12345";
//        System.out.println(mm);


            //System.exit(1);


//        List<Object> list = new ArrayList<>();
//        list.add("111");
//        list.add("8u99");
//        list.add("212");
//        System.out.println(list.size()+"=========================");
//
//
//
//
//        String s1="";
//        String s2="1";
//      if(StringUtils.isBlank(s2))
//        return;
//
//        System.out.println("1SSSSSSSSSSSSSSSS");


        Map<String, Object> map = new HashMap<>();
        map.putIfAbsent("qw","tyuo");

        System.out.println(map.getOrDefault("qw","111"));
    }

}
